#!/bin/sh
# Sets and enables heart (recommended only in daemon mode)
# case $RELEASE_COMMAND in
#   daemon*)
#     HEART_COMMAND="$RELEASE_ROOT/bin/$RELEASE_NAME $RELEASE_COMMAND"
#     export HEART_COMMAND
#     export ELIXIR_ERL_OPTIONS="-heart"
#     ;;
#   *)
#     ;;
# esac
# Set the release to work across nodes. If using the long name format like
# the one below (my_app@127.0.0.1), you need to also uncomment the
# RELEASE_DISTRIBUTION variable below.
# export RELEASE_DISTRIBUTION=name
# export RELEASE_NODE=<%= @release.name %>@127.0.0.1
export RELEASE_DISTRIBUTION=name
HOST="${LOGFLARE_NODE_HOST:-127.0.0.1}"
CLUSTER_SUFFIX="${LOGFLARE_METADATA_CLUSTER:+-$LOGFLARE_METADATA_CLUSTER}"
export RELEASE_NODE="<%= @release.name %>$CLUSTER_SUFFIX@$HOST"
